package com.ssm.demo;

import com.ssm.demo.domain.TestDomain;
import com.ssm.demo.mapper.TestMapper;
import com.ssm.demo.service.ITestService;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import java.util.List;

/**
 * @author ZhuYouBin
 * @version 1.0.0
 * @Date: 2022/9/12 11:37
 * @Description
 */
public class Test {
    public static void main(String[] args) {
        ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("spring.xml");
        TestMapper bean = context.getBean(TestMapper.class);
        List<TestDomain> query = bean.query();
        System.out.println(query);

        ITestService service = context.getBean(ITestService.class);
        service.testMybatis();
    }
}
